package com.tuanzi.loan.web.lazy.galaxycard;

import com.tuanzi.loan.core.lazy.BaseLazyDataModel;
import com.tuanzi.loan.core.util.SpringContextHolder;
import com.tuanzi.loan.core.vo.PageSearcher;
import org.springframework.data.domain.Page;

import com.tuanzi.loan.vo.request.galaxycard.GalaxyCardPrivilegeSearchRequest;
import com.tuanzi.loan.vo.response.galaxycard.GalaxyCardPrivilegeSearchResponse;
import com.tuanzi.loan.business.service.galaxycard.GalaxyCardPrivilegeService;

/**
 * 权益管理 DataModel
 * @author JinRuiyang 2018/2/8 16:09:47
 */
public class GalaxyCardPrivilegeDataModel extends BaseLazyDataModel<GalaxyCardPrivilegeSearchRequest, GalaxyCardPrivilegeSearchResponse> {

   
	private static final long serialVersionUID = -5279456995891960971L;
	
	private GalaxyCardPrivilegeService galaxycardprivilegeService = SpringContextHolder.getBean(GalaxyCardPrivilegeService.class);

    public GalaxyCardPrivilegeDataModel(GalaxyCardPrivilegeSearchRequest searchRequest) {
        super(searchRequest);
    }

    @Override
    protected Page<GalaxyCardPrivilegeSearchResponse> doLoad(PageSearcher<GalaxyCardPrivilegeSearchRequest> pageSearcher) {
        return galaxycardprivilegeService.list(pageSearcher);
    }
}
